﻿namespace HZY.Api.Admin.Controllers.DevelopmentTools.LowCode;

[ControllerDescriptor(MenuId = "请设置菜单Id 系统菜单表中查找", DisplayName = nameof(LowCodeTableController))]
public class LowCodeTableController(IServiceProvider serviceProvider)
    : AdminControllerBase<LowCodeTableService, LowCodeTable, Guid, LowCodeTable, LowCodeTable>(serviceProvider)
{
    /// <summary>
    /// 同步表
    /// </summary>
    /// <returns></returns>
    [HttpPost]
    public Task SynchronizationAsync()
    {
        return Service.SynchronizationAsync();
    }

    /// <summary>
    /// 变更数据
    /// </summary>
    /// <param name="lowCodeTables"></param>
    /// <returns></returns>
    [HttpPost]
    public Task ChangeAsync([FromBody] List<LowCodeTable> lowCodeTables)
    {
        return Service.ChangeAsync(lowCodeTables);
    }
}